package com.qf.service.impl;

import com.qf.pojo.Order;
import com.qf.service.OrderService;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.List;

@Service
public class OrderServiceImpl implements OrderService {

    @Value("${server.port}")
    private Integer port;

    @Override
    public List<Order> findByUid(Integer uid) {
        List<Order> orders = new ArrayList<>();
        orders.add(new Order(1,1000.0,"订单1-" + port,uid));
        orders.add(new Order(2,2000.0,"订单2-" + port,uid));
        orders.add(new Order(3,2000.0,"订单3-" + port,uid));
        return orders;
    }
}
